Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Check privoxy runtime logs #48

Merged
merged 11 commits into from
Jan 28, 2024
Merged

Check privoxy runtime logs #48

merged 11 commits into from
Jan 28, 2024

Conversation

Andrwe
Copy link
Owner

@Andrwe Andrwe commented Jan 28, 2024

BREAKING CHANGE

Because content filtering with Privoxy can slowdown loading websites a lot it is disabled now by default.
To enable it add the following line to your configuration which will activate all supported content filters again:

FILTERS=(
    attribute_global_name
    attribute_global_exact
    attribute_global_contain
    attribute_global_startswith
    attribute_global_endswith
    class_global
    id_global
)

During testing of these filters I got a slowdown of page loading up to 4 minutes.
This mostly depends on the amount of HTML-elements and general size of page.
The current implementation already tweaks the filters as much as possible.
Maybe additional tweaking can be done in the Privoxy configuration.

ADDED

  • privoxy-blocklist: configuration & cli-flag to activate and control content-filter conversion
  • test-suite: add configuration file to centralize test configurations
  • test-suite: add http-server to test content filters without external dependencies
  • test-suite: add tests for content filters
  • test-suite: add tests for runtime errors (close runtime errors due to generated config #46 )

CHANGES

  • privoxy-blocklist: change order of arguments of debug() to simplify writing messages
  • privoxy-blocklist: apply shfmt fixes
  • test-suite: add vim & curl to docker image to simplify debugging
  • test-suite: move check_in() and check_not_in() to conftest.py to allow re-usage in different scripts

FIXED

  • privoxy-blocklist: support for HTML element filter conversion (global filters only) (relates to Converter skips some html elements #8 )
  • privoxy-blocklist: fix several runtime errors caused by conversion routine

Andrwe added 11 commits January 11, 2024 13:27
* privoxy-blocklist: remove unnessary newline
* privoxy-blocklist: improve debug() function
* tests: add check for errors in privoxy runtime log

Signed-off-by: Andrwe Lord Weber <[email protected]>
Signed-off-by: Andrwe Lord Weber <[email protected]>
* tests: implement logix to check for content removed by privoxy
* tests: centralize test configuration in config.py
* tests: move config for python linting tools to centralized setup.cfg

Signed-off-by: Andrwe Lord Weber <[email protected]>
Signed-off-by: Andrwe Lord Weber <[email protected]>
Signed-off-by: Andrwe Lord Weber <[email protected]>
Signed-off-by: Andrwe Lord Weber <[email protected]>
@Andrwe Andrwe self-assigned this Jan 28, 2024
@Andrwe Andrwe added this to the version 0.4 milestone Jan 28, 2024
@Andrwe Andrwe merged commit 9412956 into main Jan 28, 2024
2 checks passed
@Andrwe Andrwe deleted the check_privoxy_runtime_logs branch January 28, 2024 22:35
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

runtime errors due to generated config
1 participant